home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / MacOS 8 Resources / Developer Tools / Mac OS 8 Interfaces & Libraries / Interfaces / CIncludes / ConnectionTools.h < prev    next >
C/C++ Source or Header  |  1996-05-01  |  3KB  |  142 lines

  1. /*
  2.      File:        ConnectionTools.h
  3.  
  4.      Contains:    Communications Toolbox Connection Tools Interfaces.
  5.  
  6.      Version:    Technology:    System 7.5
  7.                  Release:    Universal Interfaces 3.0d3 on Copland DR1
  8.  
  9.      Copyright:    © 1984-1996 by Apple Computer, Inc.  All rights reserved.
  10.  
  11.      Bugs?:        If you find a problem with this file, send the file and version
  12.                  information (from above) and the problem description to:
  13.  
  14.                      Internet:    apple.bugs@applelink.apple.com
  15.                      AppleLink:    APPLE.BUGS
  16.  
  17. */
  18. #ifndef __CONNECTIONTOOLS__
  19. #define __CONNECTIONTOOLS__
  20.  
  21. #ifndef __WINDOWS__
  22. #include <Windows.h>
  23. #endif
  24. #ifndef __DIALOGS__
  25. #include <Dialogs.h>
  26. #endif
  27. #ifndef __CONNECTIONS__
  28. #include <Connections.h>
  29. #endif
  30.  
  31. #ifdef __cplusplus
  32. extern "C" {
  33. #endif
  34.  
  35. #if PRAGMA_IMPORT_SUPPORTED
  36. #pragma import on
  37. #endif
  38.  
  39. #if PRAGMA_ALIGN_SUPPORTED
  40. #pragma options align=mac68k
  41. #endif
  42.  
  43. #if FOR_SYSTEM7_ONLY
  44.  
  45. enum {
  46.                                                                 /* messages for DefProc */
  47.     cmInitMsg                    = 0,
  48.     cmDisposeMsg                = 1,
  49.     cmSuspendMsg                = 2,
  50.     cmResumeMsg                    = 3,
  51.     cmMenuMsg                    = 4,
  52.     cmEventMsg                    = 5,
  53.     cmActivateMsg                = 6,
  54.     cmDeactivateMsg                = 7,
  55.     cmIdleMsg                    = 50,
  56.     cmResetMsg                    = 51,
  57.     cmAbortMsg                    = 52,
  58.     cmReadMsg                    = 100,
  59.     cmWriteMsg                    = 101,
  60.     cmStatusMsg                    = 102,
  61.     cmListenMsg                    = 103,
  62.     cmAcceptMsg                    = 104,
  63.     cmCloseMsg                    = 105,
  64.     cmOpenMsg                    = 106,
  65.     cmBreakMsg                    = 107,
  66.     cmIOKillMsg                    = 108,
  67.     cmEnvironsMsg                = 109,                            /* new connection tool messages for ctb 1.1 */
  68.     cmNewIOPBMsg                = 110,
  69.     cmDisposeIOPBMsg            = 111,
  70.     cmGetErrorStringMsg            = 112,
  71.     cmPBReadMsg                    = 113,
  72.     cmPBWriteMsg                = 114,
  73.     cmPBIOKillMsg                = 115,                            /*    messages for validate DefProc    */
  74.     cmValidateMsg                = 0,
  75.     cmDefaultMsg                = 1,                            /*    messages for Setup DefProc    */
  76.     cmSpreflightMsg                = 0,
  77.     cmSsetupMsg                    = 1,
  78.     cmSitemMsg                    = 2,
  79.     cmSfilterMsg                = 3,
  80.     cmScleanupMsg                = 4,                            /*    messages for scripting defProc    */
  81.     cmMgetMsg                    = 0,
  82.     cmMsetMsg                    = 1,                            /*    messages for localization defProc    */
  83.     cmL2English                    = 0,
  84.     cmL2Intl                    = 1
  85. };
  86.  
  87.  
  88. enum {
  89.                                                                 /* private data constants */
  90.     cdefType                    = 'cdef',                        /* main connection definition procedure */
  91.     cvalType                    = 'cval',                        /* validation definition procedure */
  92.     csetType                    = 'cset',                        /* connection setup definition procedure */
  93.     clocType                    = 'cloc',                        /* connection configuration localization defProc */
  94.     cscrType                    = 'cscr',                        /* connection scripting defProc interfaces */
  95.     cbndType                    = 'cbnd',                        /* bundle type for connection */
  96.     cverType                    = 'vers'
  97. };
  98.  
  99. struct CMDataBuffer {
  100.     Ptr                             thePtr;
  101.     long                             count;
  102.     CMChannel                         channel;
  103.     CMFlags                         flags;
  104. };
  105. typedef struct CMDataBuffer CMDataBuffer;
  106.  
  107. typedef CMDataBuffer *CMDataBufferPtr;
  108. struct CMCompletorRecord {
  109.     Boolean                         async;
  110.     SInt8                             filler;
  111.     ConnectionCompletionUPP         completionRoutine;
  112. };
  113. typedef struct CMCompletorRecord CMCompletorRecord;
  114.  
  115. typedef CMCompletorRecord *CMCompletorPtr;
  116. /*    Private Data Structure    */
  117. struct CMSetupStruct {
  118.     DialogPtr                         theDialog;
  119.     short                             count;
  120.     Ptr                             theConfig;
  121.     short                             procID;                        /* procID of the tool    */
  122. };
  123. typedef struct CMSetupStruct CMSetupStruct;
  124.  
  125. typedef CMSetupStruct *CMSetupPtr;
  126. #endif
  127.  
  128. #if PRAGMA_ALIGN_SUPPORTED
  129. #pragma options align=reset
  130. #endif
  131.  
  132. #if PRAGMA_IMPORT_SUPPORTED
  133. #pragma import off
  134. #endif
  135.  
  136. #ifdef __cplusplus
  137. }
  138. #endif
  139.  
  140. #endif /* __CONNECTIONTOOLS__ */
  141.  
  142.